+Thu Jul 12 14:06:19 2001 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkmenubar.c (gtk_menu_bar_hierarchy_changed): Add
+ missing case.
+
+ * gtk/gtkcontainer.c (gtk_container_get_focus_chain): Fix
+ NULL/FALSE return value confusion.
+
+ * gtk/gtkrange.c (coord_to_value): Fix division-by-zero
+ problem when scrollbar completely fills range. (Patch
+ from Matthias Clasen, #57047)
+
Thu Jul 12 13:53:28 2001 Owen Taylor <otaylor@redhat.com>
* gdk/x11/gdkevents-x11.c (gdk_event_translate): Properly
+Thu Jul 12 14:06:19 2001 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkmenubar.c (gtk_menu_bar_hierarchy_changed): Add
+ missing case.
+
+ * gtk/gtkcontainer.c (gtk_container_get_focus_chain): Fix
+ NULL/FALSE return value confusion.
+
+ * gtk/gtkrange.c (coord_to_value): Fix division-by-zero
+ problem when scrollbar completely fills range. (Patch
+ from Matthias Clasen, #57047)
+
Thu Jul 12 13:53:28 2001 Owen Taylor <otaylor@redhat.com>
* gdk/x11/gdkevents-x11.c (gdk_event_translate): Properly
+Thu Jul 12 14:06:19 2001 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkmenubar.c (gtk_menu_bar_hierarchy_changed): Add
+ missing case.
+
+ * gtk/gtkcontainer.c (gtk_container_get_focus_chain): Fix
+ NULL/FALSE return value confusion.
+
+ * gtk/gtkrange.c (coord_to_value): Fix division-by-zero
+ problem when scrollbar completely fills range. (Patch
+ from Matthias Clasen, #57047)
+
Thu Jul 12 13:53:28 2001 Owen Taylor <otaylor@redhat.com>
* gdk/x11/gdkevents-x11.c (gdk_event_translate): Properly
+Thu Jul 12 14:06:19 2001 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkmenubar.c (gtk_menu_bar_hierarchy_changed): Add
+ missing case.
+
+ * gtk/gtkcontainer.c (gtk_container_get_focus_chain): Fix
+ NULL/FALSE return value confusion.
+
+ * gtk/gtkrange.c (coord_to_value): Fix division-by-zero
+ problem when scrollbar completely fills range. (Patch
+ from Matthias Clasen, #57047)
+
Thu Jul 12 13:53:28 2001 Owen Taylor <otaylor@redhat.com>
* gdk/x11/gdkevents-x11.c (gdk_event_translate): Properly
+Thu Jul 12 14:06:19 2001 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkmenubar.c (gtk_menu_bar_hierarchy_changed): Add
+ missing case.
+
+ * gtk/gtkcontainer.c (gtk_container_get_focus_chain): Fix
+ NULL/FALSE return value confusion.
+
+ * gtk/gtkrange.c (coord_to_value): Fix division-by-zero
+ problem when scrollbar completely fills range. (Patch
+ from Matthias Clasen, #57047)
+
Thu Jul 12 13:53:28 2001 Owen Taylor <otaylor@redhat.com>
* gdk/x11/gdkevents-x11.c (gdk_event_translate): Properly
+Thu Jul 12 14:06:19 2001 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkmenubar.c (gtk_menu_bar_hierarchy_changed): Add
+ missing case.
+
+ * gtk/gtkcontainer.c (gtk_container_get_focus_chain): Fix
+ NULL/FALSE return value confusion.
+
+ * gtk/gtkrange.c (coord_to_value): Fix division-by-zero
+ problem when scrollbar completely fills range. (Patch
+ from Matthias Clasen, #57047)
+
Thu Jul 12 13:53:28 2001 Owen Taylor <otaylor@redhat.com>
* gdk/x11/gdkevents-x11.c (gdk_event_translate): Properly
+Thu Jul 12 14:06:19 2001 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkmenubar.c (gtk_menu_bar_hierarchy_changed): Add
+ missing case.
+
+ * gtk/gtkcontainer.c (gtk_container_get_focus_chain): Fix
+ NULL/FALSE return value confusion.
+
+ * gtk/gtkrange.c (coord_to_value): Fix division-by-zero
+ problem when scrollbar completely fills range. (Patch
+ from Matthias Clasen, #57047)
+
Thu Jul 12 13:53:28 2001 Owen Taylor <otaylor@redhat.com>
* gdk/x11/gdkevents-x11.c (gdk_event_translate): Properly
gtk_container_get_focus_chain (GtkContainer *container,
GList **focus_chain)
{
- g_return_val_if_fail (GTK_IS_CONTAINER (container), NULL);
+ g_return_val_if_fail (GTK_IS_CONTAINER (container), FALSE);
if (focus_chain)
{
toplevel = gtk_widget_get_toplevel (widget);
if (old_toplevel)
- remove_from_window (old_toplevel, menubar);
+ remove_from_window (old_toplevel, GTK_WINDOW (menubar));
if (GTK_WIDGET_TOPLEVEL (toplevel))
add_to_window (GTK_WINDOW (toplevel), menubar);
gdouble value;
if (range->orientation == GTK_ORIENTATION_VERTICAL)
- frac = ((coord - range->layout->trough.y) /
- (gdouble) (range->layout->trough.height - range->layout->slider.height));
+ if (range->layout->trough.height == range->layout->slider.height)
+ frac = 1.0;
+ else
+ frac = ((coord - range->layout->trough.y) /
+ (gdouble) (range->layout->trough.height - range->layout->slider.height));
else
- frac = ((coord - range->layout->trough.x) /
- (gdouble) (range->layout->trough.width - range->layout->slider.width));
+ if (range->layout->trough.width == range->layout->slider.width)
+ frac = 1.0;
+ else
+ frac = ((coord - range->layout->trough.x) /
+ (gdouble) (range->layout->trough.width - range->layout->slider.width));
if (should_invert (range))
frac = 1.0 - frac;